/****************************************************************************
 * Elisa 1.0                                                                *
 *--------------------------------------------------------------------------*
 * Author: Laurent Granvilliers, Vincent Sorin                              *
 * Copyright (c) 2004 Laboratoire d'Informatique de Nantes Atlantique       *
 *--------------------------------------------------------------------------*
 * Elisa is distributed WITHOUT ANY WARRANTY. Read the associated           *
 * COPYRIGHT file for more details.                                         *
 *--------------------------------------------------------------------------*
 * elisa_sortable.cpp                                                       *
 ****************************************************************************/

#include "elisa_sortable.h"


USING_ELISA


//--------------------------------------------------------------------------
// class SortQueue
//--------------------------------------------------------------------------
void SortQueue::clear()
{
	while (!(_q.empty())) _q.pop();
}


//--------------------------------------------------------------------------
// class SortStack
//--------------------------------------------------------------------------
void SortStack::clear()
{
	while (!(_s.empty())) _s.pop();
}


//--------------------------------------------------------------------------
// Mutation functions
//--------------------------------------------------------------------------
BaseSortContainer *elisa::muteSortQueue(BaseSortContainer *b)
{
	return elisa::muteSortContainer<SortQueue>(b);
}

BaseSortContainer *elisa::muteSortStack(BaseSortContainer *b)
{
	return elisa::muteSortContainer<SortStack>(b);
}

BaseSortContainer *elisa::muteSortSet(BaseSortContainer *b)
{
	return elisa::muteSortContainer<SortSet>(b);
}
